#ifndef GUIMAP_H_
#define GUIMAP_H_

#include "map/Map.h"
#include "map/Intersection.h"
#include "map/RoadSegment.h"
#include "gui/objects/GUIObjectsContainer.h"
#include "util/LinkedList.h"

namespace gui {

class GUIMap: public GUIObjectsContainer {
public:

	GUIMap(GUIObjectDrawer* drawer, Map* map);

	virtual ~GUIMap();

	virtual int getWidth() { return this->rightmost - this->leftmost + 2 * CHANGUI_IN_PIXELS; }

	virtual int getHeight() { return this->bottommost - this->topmost + 2 * CHANGUI_IN_PIXELS; }

	virtual int getLeftmost() { return this->leftmost - CHANGUI_IN_PIXELS; }

	virtual int getTopmost() { return this->topmost - CHANGUI_IN_PIXELS; }

	virtual void addGUIBaseSegment(RoadSegment* roadSegment);

	virtual void addGUIIntersection(Intersection* intersection, RoadType type);

	virtual void addGUIRoadSegment(RoadSegment* roadSegment);

	virtual void addGUIRoadArrow(RoadSegment* roadSegment, bool inverted = false);

	virtual void addGUIRouteIntersection(MapPoint intersection);

	virtual void addGUIMapLocation(MapLocation* mapLocation);

private:
	const static int CHANGUI_IN_PIXELS = 30;
	GUIObjectFactory factory;
	Map* map;

};

}

#endif /* GUIMAP_H_ */
